#ifndef _SYS_IO_ERR_H_
#define _SYS_IO_ERR_H_

#include "Err.h"
#include "SysTypes.h"

#define IO_ERR_VTABLE(self)   ((IOErrVTable*)((FanObj*)self)->vtable)


extern Type*    IOErr_classType;
extern VTable*  IOErr_classVTable;


/* [sys::IOErr] Attributes */
struct IOErr
{
  Err           super;
};


/* [sys::IOErr] Virtual-table */
typedef struct IOErrVTable
{
  ErrVTable     super;
} IOErrVTable;


/* [sys::IOErr] Methods and fields */
void            IOErr_make_0(IOErr* self);
void            IOErr_make_1(IOErr* self, Str* msg);
void            IOErr_make(IOErr* self, Str* msg, Err* cause);


/* [sys::IOErr] Extra methods */
IOErr*          IOErr_new(Str* msg, Err* cause);
IOErr*          IOErr_newWithFormattedMsg(const char* msgFormat, ...);


/* [sys::IOErr] Type-system functions */
Type*           IOErr_initType(void);
VTable*         IOErr_initVTable(void);
void            IOErr_initStatic(void);


#endif
